package io.renren.modules.driver.dao;

import io.renren.modules.driver.entity.SjDriverEntity;
import io.renren.modules.sys.dao.BaseDao;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 司机表
 * 
 * @author chenshun
 * @email sunlightcs@gmail.com
 * @date 2017-11-30 18:18:19
 */
@Mapper
public interface SjDriverDao extends BaseDao<SjDriverEntity> {

    SjDriverEntity queryObjectByUserName(String username);

    List<SjDriverEntity> queryCollectedListByUserId(Long userId);

    Map<String, Object> queryMineInfo(Long driverId);

    List<Map<String,Object>> queryIncomeGroupByMonth(Long driverId);

    Map<String,Object> queryBalanceInfo(Long driverId);

    List<Map<String,Object>> queryIncomeDetail(Long driverId);

    Map<String,Object> queryIncomeByIuputMonth(@Param("driverId") Long driverId, @Param("month") String month);

    List<Map<String,Object>> queryIncomeDetailByIuputMonth(@Param("driverId") Long driverId, @Param("month") String month);



    /**
     * 司机财务模块展示
     */
    List<SjDriverEntity> sjFinancelist(Map<String, Object> map);
    int sjFinancelistTotal(Map<String, Object> map);

}
